From: Jonas Ã…dahl Date: Wed, 17 Aug 2022 14:26:14 +0000 (+0200) Subject: shell-global: Get backend from context X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~405^2^2~237 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=009da0df6481011845865760e7c037cf0484bc9f;p=gnome-shell.git shell-global: Get backend from context Part-of: --- diff --git a/src/shell-global.c b/src/shell-global.c index baa28e6d6..ab8000e23 100644 --- a/src/shell-global.c +++ b/src/shell-global.c @@ -1022,6 +1022,7 @@ void _shell_global_set_plugin (ShellGlobal *global, MetaPlugin *plugin) { + MetaContext *context; MetaDisplay *display; MetaBackend *backend; MetaSettings *settings; @@ -1029,13 +1030,15 @@ _shell_global_set_plugin (ShellGlobal *global, g_return_if_fail (SHELL_IS_GLOBAL (global)); g_return_if_fail (global->plugin == NULL); - global->backend = meta_get_backend (); + display = meta_plugin_get_display (plugin); + context = meta_display_get_context (display); + backend = meta_context_get_backend (context); global->plugin = plugin; global->wm = shell_wm_new (plugin); - display = meta_plugin_get_display (plugin); global->meta_display = display; global->meta_context = meta_display_get_context (display); + global->backend = meta_context_get_backend (context); global->workspace_manager = meta_display_get_workspace_manager (display); global->stage = CLUTTER_STAGE (meta_get_stage_for_display (display)); @@ -1087,7 +1090,7 @@ _shell_global_set_plugin (ShellGlobal *global, g_signal_connect_object (global->meta_display, "x11-display-closing", G_CALLBACK (on_x11_display_closed), global, 0); - backend = meta_get_backend (); + backend = meta_context_get_backend (shell_global_get_context (global)); settings = meta_backend_get_settings (backend); g_signal_connect (settings, "ui-scaling-factor-changed", G_CALLBACK (ui_scaling_factor_changed), global);